<include file="public:header" />
<form id="info_form" action="{:u('score_item/edit')}" method="post" enctype="multipart/form-data">
<div class="pad_lr_10">
	<div class="col_tab">
		<ul class="J_tabs tab_but cu_li">
			<li class="current">基本资料</li>
            <li class="current">商品描述</li>
		</ul>
		<div class="J_panes">
			<div class="content_list pad_10">
				<table width="100%" cellspacing="0" class="table_form">
					<tr>
						<th width="120">{:L('article_cateid')} :</th>
						<td>
						<select name="cate_id" id="cate_id">
            			<option value="">--请选择分类--</option>
            			<volist name="cate_list" id="val">
            			<option value="{$val.id}" <if condition="$info['cate_id'] eq $val['id']">selected="selected"</if>>{$val.name}</option>
            			</volist>
            			</select>
						</td>
					</tr>
		            <tr>
						<th>商品名称 :</th>
						<td>
		                    <input type="text" name="title" id="J_title"class="input-text iColorPicker" size="60" value="{$info.title}">
		                </td>
					</tr>
		            <tr>
						<th>{:L('article_img')} :</th>
						<td>
                        <notempty name="info.img">
                        <span class="attachment_icon J_attachment_icon" file-type="image" file-rel="{:attach($info['img'], 'score_item')}">
                        <img src="{:attach($info['img'], 'score_item')}" style="width:100px; height:100px;" /></span>
                        </notempty><br />
                        <input type="file" name="img" class="input-text"  style="width:200px;" />
                        </td>
		 			</tr>
					<tr>
						<th>所需积分 :</th>
						<td><input type="text" name="score" id="score" class="input-text" value="{$info.score}" size="10" onkeyup="this.value=this.value.replace(/[^0-9.]/g,'')" onafterpaste="this.value=this.value.replace(/[^0-9.]/g,'')"></td>
					</tr>
					<tr>
						<th>库存 :</th>
						<td><input type="text" name="stock" id="stock" class="input-text" value="{$info.stock}" size="10" onkeyup="this.value=this.value.replace(/[^0-9.]/g,'')" onafterpaste="this.value=this.value.replace(/[^0-9.]/g,'')"></td>
					</tr>     
					<tr>
						<th>每人限兑换数 :</th>
						<td><input type="text" name="user_num" id="user_num" value="{$info.user_num}" class="input-text" size="10" onkeyup="this.value=this.value.replace(/[^0-9.]/g,'')" onafterpaste="this.value=this.value.replace(/[^0-9.]/g,'')"></td>
					</tr> 
					<tr>
						<th>排序值 :</th>
						<td><input type="text" name="ordid" value="{$info.ordid}" id="ordid" class="input-text" size="10" onkeyup="this.value=this.value.replace(/[^0-9.]/g,'')" onafterpaste="this.value=this.value.replace(/[^0-9.]/g,'')"></td>
					</tr>
				</table>
			</div>
            <div class="content_list pad_10 hidden">
				<table width="100%" cellspacing="0" class="table_form">
                	<tr>
						<th>商品描述 :</th>
		                <td><textarea name="desc" id="desc" style="width:68%;height:400px;visibility:hidden;resize:none;">{$info.desc}</textarea></td>
					</tr>
				</table>
			</div>
        </div>
		<div class="mt10"><input type="submit" value="{:L('submit')}" id="dosubmit" name="dosubmit" class="btn btn_submit" style="margin:0 0 10px 100px;"><br /><br /><br /></div>
	</div>
</div>
<input type="hidden" name="menuid"  value="{$menuid}"/>
<input type="hidden" name="id" id="id" value="{$info.id}" />
</form>
<include file="public:footer" />
<script src="__STATIC__/js/kindeditor/kindeditor.js"></script>
<script type="text/javascript">
$('.J_cate_select').cate_select('请选择');
$(function() {
	KindEditor.create('#desc', {
		uploadJson : '{:U("attachment/editer_upload")}',
		fileManagerJson : '{:U("attachment/editer_manager")}',
		allowFileManager : true
	});
	$('ul.J_tabs').tabs('div.J_panes > div');
});
</script>
</body>
</html>